/**
 * @author junyu33
 * 2022,05,07
 */
import java.util.Vector;

public class ManagementCttee {
    /**
     * list of senior members
     */
    private Vector<SeniorMember> seniorMembers = new Vector<SeniorMember>();

    /**
     * add a committee member from a senior member
     * @param s
     */
    public void addCtteeMember(SeniorMember s) {
        seniorMembers.add(s);
    }

    /**
     * remove a committee member from list of senior members
     * @param name
     */
    public void removeCtteeMember(String name) {
        for (SeniorMember i : seniorMembers) {
            if(i.getName().equals(name)) {
                seniorMembers.removeElement(i);
                return;
            }
        }
        System.out.println("This member does not exist.");
    }

    /**
     * show all senior members' name
     */
    public void showCtteeMember() {
        System.out.println("CtteeMember list: ");
        for (SeniorMember i : seniorMembers) {
            System.out.println(i.getName());
        }
    }
}
